import { Vue } from 'vue-property-decorator';
import Invest from '@/common/dict/invest';
import moment from 'moment';
import { PrefixInteger, numberFormat, unitShow, timeFormat, dateFormat, objToVxeFilterArr } from '@/utils/tools';
import DictionConstUtil from '@/utils/diction-const-util';

export default class BatchColumnUtil extends Vue {
    invest: any = new Invest();

    // 选中的证券
    selectedStockColumns: any[] = [
        {
            name: '操作',
            type: 'btn',
            btns: [{ title: '删除', type: 'primary', icon: 'el-icon-close' }],
            width: 60,
            fixed: 'left',
        },
        { name: '证券代码', val: 'stockCode' },
        { name: '证券名称', val: 'stockName' },
        { name: '申报代码', val: 'reportCode' },
        { name: '证券类别', val: 'stockTypeName' },
        { name: '市场类型', val: 'marketName' },
    ];

    // 选中的可投标债券
    selectedBidStockColumns: any[] = [
        {
            name: '操作',
            type: 'btn',
            btns: [{ title: '删除', type: 'primary', icon: 'el-icon-close' }],
            width: 60,
            fixed: 'left',
        },
        { name: '证券代码', val: 'bondCode' },
        { name: '证券名称', val: 'bondNameSt' },
        {
            name: '招标标的',
            val: 'bidSubject',
            minWidth: '110px',
            type: 'func',
            funcBody: (value, row) => (row.bidSubject === '1' ? '利率' : row.bidSubject === '3' ? '价格' : '--'),
        },
        { name: '缴款日期', val: 'payDate', type: 'func', funcBody: value => dateFormat(value) || '--' },
        { name: '上市日期', val: 'listDate', type: 'func', funcBody: value => dateFormat(value) || '--' },
    ];

    // 选中的银行
    selectedBankColumns: any[] = [
        {
            name: '操作',
            type: 'btn',
            btns: [{ title: '删除', type: 'primary', icon: 'el-icon-close' }],
            width: 60,
            fixed: 'left',
        },
        { name: '银行编码', val: 'bankCode' },
        { name: '银行全称', val: 'bankName' },
        { name: '银行名称', val: 'bankNameSt' },
    ];

    // 选中的可支取存单
    selectedPaidColumns: any[] = [
        {
            name: '操作',
            type: 'btn',
            btns: [{ title: '删除', type: 'primary', icon: 'el-icon-close' }],
            width: 60,
            fixed: 'left',
        },
        { name: '存单号', val: 'receiptNo', minWidth: 100 },
        { name: '兑付金额', val: 'orderBalance' },
        { name: '利息金额', val: 'drawInterest' },
    ];

    // 交易所指令明细字段
    exchangeDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '指令价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '指令金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '价格模式', id: 'priceType' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];

    // 银行间债券指令明细字段
    bondDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
        ],
        [
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
            { content: '证券类别', id: 'stockType' },
        ],
        [
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
        [
            {
                content: '券面总额(万元)',
                id: 'faceTotalBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, '万元') : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '净价价格(元)',
                id: 'netPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '全价价格(元)',
                id: 'fullPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: ' 净价金额(元)',
                id: 'netBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: ' 总应计利息(元)',
                id: 'netBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '结算金额(元)',
                id: 'settleBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '结算日期',
                id: 'settleDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '清算速度',
                id: 'clearSpeed',
                needFormat: true,
                formatter: value => (value ? 'T+' + value : 'T+0'),
            },
        ],
    ];

    // 银行间回购指令明细字段
    buybackDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
        ],
        [
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
            { content: '证券类别', id: 'stockType' },
        ],
        [
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
        [
            {
                content: '回购金额',
                id: 'repoBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '回购天数',
                id: 'repoDay',
            },
            {
                content: '实际占款天数',
                id: 'actualDay',
                needFormat: true,
                formatter: (value, row) => moment(row.secondSettleDate).diff(row.firstSettleDate, 'day'),
            },
            {
                content: '首次结算日期',
                id: 'firstSettleDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '到期结算日期',
                id: 'secondSettleDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '清算速度',
                id: 'clearSpeed',
                needFormat: true,
                formatter: value => (value ? 'T+' + value : 'T+0'),
            },
            {
                content: '回购利率(%)',
                id: 'repoRate',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '应计利息',
                id: 'tDayInterest',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '到期回购金额',
                id: 'dueRepoBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '交易对手',
                id: 'opponentName',
            },
        ],
    ];

    // 申购指令明细字段
    purchaseDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '申购价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '申购数量(股)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '申购金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '交易对手编码', id: 'opponentCode' },
            { content: '交易对手名称', id: 'opponentName' },
            { content: '币种', id: 'curName' },
        ],
        [
            { content: '交易市场', id: 'marketName' },
            {
                content: '申购定金(元)',
                id: 'earnestBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
    ];

    // 债券一级投标指令明细
    primaryBondDetailFields: any[] = [
        [
            { content: '投标序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '投标状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
        ],
        [
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '债券代码', id: 'stockCode' },
            { content: '债券名称', id: 'stockName' },
            {
                content: '投标金额(万元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '投标方式', id: 'tenderWay' },
            { content: '投资类型', id: 'investType' },
        ],
        [
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
        [
            {
                content: '投标日期',
                id: 'bidStartDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '投标截止日期',
                id: 'bidEndDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '缴款日期',
                id: 'payDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '上市日期',
                id: 'listDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
            {
                content: '发行规模(亿)',
                id: 'totalBalance',
                needFormat: true,
                formatter: value => numberFormat(value, '亿元') || '--',
            },
            {
                content: '债券类别',
                id: 'stockType',
                // needFormat: true,
                // formatter: value => (value ? this.getBondType(value) : '--'),
            },
            {
                content: '发行人',
                id: 'issueName',
            },
        ],
        [
            {
                content: '发行人性质',
                id: 'issuerNature',
            },
            {
                content: '信用评级(主体/债券)',
                id: 'grade',
                needFormat: true,
                formatter: (value, row) => row.issueGrade + '/' + row.bondGrade,
            },
        ],
    ];

    // 转融通指令明细
    refinanceDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
        ],
        [
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
            { content: '证券类别', id: 'stockType' },
        ],
        [
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '期限(天)', id: 'deadline' },
            { content: '费率(%)', id: 'rate' },
            { content: '融出数量(股)', id: 'instAmount' },
            { content: '交易对手代码', id: 'opponentCode' },
        ],
        [
            { content: '交易对手名称', id: 'opponentName' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];

    // 存款指令明细
    depositDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
        ],
        [
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
            { content: '证券类别', id: 'stockType' },
        ],
        [
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
        [
            {
                content: '存款类型',
                id: 'depositType',
                needFormat: true,
                formatter: value => this.invest.depositType[value] || '--',
            },
            {
                content: '通知天数(天)',
                id: 'noticeDay',
            },
            {
                content: '支取类型',
                id: 'advanceType',
                needFormat: true,
                formatter: value => this.invest.advanceLimitFlag[value],
            },
            {
                content: '银行总行代码',
                id: 'bankCode',
            },
            {
                content: '银行总行名称',
                id: 'bankName',
            },
            {
                content: '起息日',
                id: 'startExtraDay',
                needFormat: true,
                formatter: (value, row) =>
                    moment(row.dueDate)
                        .subtract(row.depositTerm, 'days')
                        .format('YYYY-MM-DD'),
            },
            {
                content: '到期日期',
                id: 'dueDate',
                needFormat: true,
                formatter: value => (value ? dateFormat(value, true) : '--'),
            },
        ],
        [
            {
                content: '存款期限(天)',
                id: 'depositTerm',
            },
            {
                content: '存款金额(元)',
                id: 'depositBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '存款利率(%)',
                id: 'depositRate',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '存款利息(元)',
                id: 'depositInterest',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '到期金额(元)',
                id: 'dueBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
    ];

    // 期货指令明细
    futrueGoodsDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '指令价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '指令金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '合约代码', id: 'stockCode' },
            { content: '合约名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];

    // 场外指令明细
    cwDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '指令价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '指令金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '币种', id: 'curName' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];

    // 上交所指令明细
    shFixedDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '净价价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '净价金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '交易对手编码', id: 'opponentCode' },
            { content: '交易对手名称', id: 'opponentName' },
            { content: '全价价格', id: 'fullPrice' },
        ],
        [
            { content: '全价金额', id: 'fullBalance' },
            { content: '总应计利息', id: 'totalInterest' },
            { content: '到期收益率', id: 'yield' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];

    // 交易所大宗
    exchangeBulkDetailFields: any[] = [
        [
            { content: '指令序号', id: 'instructionNo' },
            { content: '指令批号', id: 'batchNo' },
            {
                content: '指令状态',
                id: 'instStatus',
                // needFormat: true,
                // formatter: value => (value != undefined ? this.instructionStatus[value] : '--'),
            },
            { content: '下达人', id: 'directUserName' },
            {
                content: '下达时间',
                id: 'directTime',
                needFormat: true,
                formatter: (value, row) => dateFormat(row['directDate']) + ' ' + timeFormat(row['directTime']) || '--',
            },
            {
                content: '指令价格(元)',
                id: 'instPrice',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            {
                content: '指令数量(张)',
                id: 'instAmount',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
        ],
        [
            {
                content: '指令金额(元)',
                id: 'instBalance',
                needFormat: true,
                formatter: value => (value != undefined ? numberFormat(value, 2) : '--'),
            },
            { content: '产品代码', id: 'fundCode' },
            { content: '产品名称', id: 'fundName' },
            { content: '组合编码', id: 'fundAccountCode' },
            { content: '组合名称', id: 'fundAccountName' },
            { content: '证券代码', id: 'stockCode' },
            { content: '证券名称', id: 'stockName' },
        ],
        [
            { content: '证券类别', id: 'stockTypeName' },
            { content: '投资类型', id: 'investType' },
            { content: '业务类型', id: 'businessTypeName' },
            { content: '委托方向', id: 'orderDirection' },
            { content: '价格模式', id: 'priceType' },
            { content: '交易对手代码', id: 'opponentCode' },
            { content: '交易市场', id: 'marketName' },
        ],
    ];
}
